﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace WindowsFormsApplication1
{
    public partial class staffpj : Form
    {
        private string staffid = "";
        private string staffname = "";
        dbutils db = new dbutils();
        public staffpj()
        {
            InitializeComponent();
        }
        public void set_value(string staffid,string staffname){
            this.staffid = staffid;
            this.staffname = staffname;
        }

        private void staffpj_Load(object sender, EventArgs e)
        {
            string sql = "select * from pingjia where staffid='" + staffid + "'";
            string text = db.select_one(sql, 3);
            if (text == null)
                return;
            string grade = db.select_one(sql, 4);
            string date = db.select_one(sql, 2);

            label1.Text += staffname;
            label2.Text += staffid;
            label3.Text += grade;
            label5.Text += date;
            textBox1.Text = text;

        }


    }
}
